<?php
	//引入配置文件和数据操作函数
	require '../../public/config.php';
	require '../../public/mysql.php';
	require '../../public/function.php';
	//获取传递过来的操作
	$action = $_GET['a'];
	//判断操作
	switch ($action) {
		case 'doship':
			$id = $_GET['id'];
			$ship = $_GET['ssship'];
			if($ship=='0'){
				echo '1';
				$ship='1';
			}
			//ship收货
			$link = connect();
			if ($link['error']) {
				$sql1 = "update order_detail set ship='{$ship}' where id ='{$id}'";
				$result1 = excute($link['mess'], $sql1);
			}
			$ship=$result1;
			header('location:./orderList.php');
	}
?>